package org.geekbang.thinking.in.spring.conversion;

import com.think.in.spring.ioc.overview.domain.User;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

/**
 * @author : zjj
 * @date : 2022/3/7 15:49
 */
public class SpringCustomizedPropertyEditorDemo {

    public static void main(String[] args) {
        // 构建容器
        ConfigurableApplicationContext applicationContext =
                new ClassPathXmlApplicationContext("classpath:/META-INF/property-editors-context.xml");

        User user = applicationContext.getBean("user", User.class);

        System.out.println(user);
        // 关闭容器
        applicationContext.close();
    }
}
